﻿<%@ Page Title="Metas" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true"
    CodeBehind="Meta.aspx.cs" Inherits="Follow.Cadastros.Meta" %>

<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <div class="Titulo">
        <%: Title %><br />
        <asp:Image ID="imgTitulo" runat="server" ImageUrl="~/images/linhas_17.png" />
    </div>
    <asp:Label ID="lblMsg" runat="server" CssClass="lblMsg" Visible="false"/><br />
    <asp:MultiView ID="mvMetas" runat="server" ActiveViewIndex="0">
        <asp:View ID="View1" runat="server">
            <div class="subTitulo">
                <asp:Label ID="lblTitulo1" runat="server" Text="Lista de Metas" />
            </div>
            <div id="divMsg1" class="isa_info" runat="server" visible="false" >
                <asp:Label ID="lblMsg1" runat="server" Text="Mensagem." />
            </div>
            <div class="divPesquisa">
                <asp:Label ID="lblPesquisa" Text="Pesquisa:" runat="server" /><br />
                <asp:TextBox ID="txtPesquisa" runat="server" Width="300px" Height="25px" />
                <asp:Button ID="btnPesquisa" runat="server" Text="Pesquisar" OnClick="btnPesquisa_Click"
                    CssClass="Botao" />
                <asp:Button ID="btnIncluir" runat="server" Text="Incluir" OnClick="btnIncluir_Click"
                    CssClass="Botao" /><br />
            </div>
            <br />
            <br />
            <asp:GridView ID="gvMetas" runat="server" AllowPaging="True" AutoGenerateColumns="False"
                DataKeyNames="IDMeta" OnRowCommand="gvMetas_RowCommand"  Width="765px"
                BackColor="White" BorderColor="#DEDFDE" BorderStyle="None" BorderWidth="1px" 
                CellPadding="4" ForeColor="Black" GridLines="Vertical" 
                onselectedindexchanged="gvMetas_SelectedIndexChanged">
                <AlternatingRowStyle BackColor="White" />
                <Columns>
                    <asp:BoundField HeaderText="Nome" DataField="Nome" />
                    <asp:BoundField HeaderText="Tipo" DataField="Tipo" />
                    <asp:ButtonField ButtonType="image" ImageUrl="~/Images/editar.png" CommandName="Editar"
                        HeaderText="Editar" ItemStyle-HorizontalAlign="Center" />
                    <asp:ButtonField ButtonType="image" ImageUrl="~/Images/excluir.png" CommandName="Excluir"
                        HeaderText="Excluir" ItemStyle-HorizontalAlign="Center" />
                </Columns>
                <FooterStyle BackColor="#CCCC99" />
                <HeaderStyle BackColor="#6B696B" Font-Bold="True" ForeColor="White" />
                <PagerStyle BackColor="#F7F7DE" ForeColor="Black" HorizontalAlign="Right" />
                <RowStyle BackColor="#F7F7DE" />
                <SelectedRowStyle BackColor="#CE5D5A" Font-Bold="True" ForeColor="White" />
                <SortedAscendingCellStyle BackColor="#FBFBF2" />
                <SortedAscendingHeaderStyle BackColor="#848384" />
                <SortedDescendingCellStyle BackColor="#EAEAD3" />
                <SortedDescendingHeaderStyle BackColor="#575357" />
            </asp:GridView>
        </asp:View>
        <asp:View ID="View2" runat="server">
            <div class="subTitulo">
                <asp:Label ID="lblTitulo2" runat="server" Text="Inserir nova Meta" />
            </div>
            <div id="divMsg2" class="isa_info" runat="server" visible="false" >
                <asp:Label ID="lblMsg2" runat="server" Text="Mensagem." />
            </div>
            <asp:HiddenField ID="IDMeta" runat="server" />
            <asp:Label ID="lblNome" runat="server" Text="Nome:" /><br />
            <asp:TextBox ID="txtNome" runat="server" />
                <asp:RequiredFieldValidator ID="rfvNome" runat="server" ErrorMessage="* Campo Nome não preenchido." ForeColor="Red"
                    ControlToValidate="txtNome" Font-Size="X-Small"></asp:RequiredFieldValidator><br />
            <br />
            <asp:Label ID="lblTipo" runat="server" Text="Tipo:" />
            <br />
            <asp:DropDownList ID="ddlTipoMeta" runat="server">
                <asp:ListItem Text="Visita" Value="Visita" />
                <asp:ListItem Text="Proposta" Value="Proposta" />
            </asp:DropDownList>
            <br />
            <br />
            <asp:Button ID="btnSalvar" runat="server" Text="Salvar" OnClick="btnSalvar_Click" CssClass="Botao"/>
            <asp:Button ID="btnVoltar" runat="server" Text="Voltar" OnClick="btnVoltar_Click" CssClass="Botao" CausesValidation="false"/>
            <br />
        </asp:View>
    </asp:MultiView>
</asp:Content>
